package com.kern.academic.bean.enumer;

/**
 * 移除操作的枚举类型
 * Created by caoshi at 21:00 2021-07-12
 */
public enum  RemoveOperEnum {

    /* 缺少删除操作的必需参数, 如 id等 */
    NECESSARY_PARAMS_NOT_EXIT(-2, "缺少必要参数"),

    /* 要删除的对象不存在 */
    USER_NOT_EXIT(-1, "要删除的对象不存在!"),

    /* 删除操作失败! */
    REMOVE_FAIL(0, "删除失败!"),

    /* 删除操作成功! */
    REMOVE_SUCCESS(1, "删除成功!");

    private final int code;
    private final String info;

    RemoveOperEnum(int code, String info) {
        this.code = code;
        this.info = info;
    }

    public int getCode() {
        return code;
    }

    public String getInfo() {
        return info;
    }
}
